import request from '@/utils/request'

// 查询告警设置列表
export function listWaring(query) {
  return request({
    url: '/lock/waring/list',
    method: 'get',
    params: query
  })
}

// 查询告警设置详细
export function getWaring() {
  return request({
    url: '/lock/waring/getUserId',
    method: 'get'
  })
}

// 新增告警设置
export function addWaring(data) {
  return request({
    url: '/lock/waring',
    method: 'post',
    data: data
  })
}

// 修改告警设置
export function updateWaring(data) {
  return request({
    url: '/lock/waring',
    method: 'put',
    data: data
  })
}

// 删除告警设置
export function delWaring(userId) {
  return request({
    url: '/lock/waring/' + userId,
    method: 'delete'
  })
}
